package com.futureweaver.controller;

import com.futureweaver.domain.Disease;
import com.futureweaver.service.DiseaseService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;
import org.w3c.dom.stylesheets.LinkStyle;

import java.util.List;

@RequestMapping("/disease")
@Controller
public class DiseaseController {

    @Autowired
    private DiseaseService service;

    @RequestMapping("/query")
    @ResponseBody
    public List<Disease> query(@RequestBody Disease disease) {
        return service.query(disease);
    }
}
